function signal = chu_sequence(length)
% chu sequence generate
% input:
%       length: desired chu sequence length
% output:
%       signal: chu sequence generated, array
% I_n = cos(theta_n),0<=n<length
% Q_n = sin(theta_n),0<=n<length
% theta_n = pi*n^2/length
    signal = zeros(length,1);
    for i = 0:length-1
        signal(i+1) = exp(sqrt(-1)*pi*i*i/length);
    end
end

